{{define "Irrigate"}}
  {{template "LayoutHeader" .}}
    <p>Use the the controls below to run sprinklers for a specific zone.</p>

    <form action="" method=post>
      <fieldset>
        <legend>Activate Sprinklers</legend>
        Water zone
        <select name=zone>
          {{.zoneOptions}}
        </select>
        for
        <select name=secs>
          {% for i in secs_and_mins %}
            <option value="{{.i.0|html}}">{{.i.1|html}}</option>
          {% endfor %}
        </select>
        minute(s)
        <input type=submit name=water-zone value=Water> |
        <input type=submit name=get-system-status value="Get System Status"> |
        <input type=submit name=turn-off-everything value="Turn Off Everything">
      </fieldset>
    </form>

    {{with .status}}
      <form>
        <fieldset>
          <legend>Status</legend>
          {{.|html}}
        </fieldset>
      </form>
    {{end}}
  {{template "LayoutFooter" .}}
{{end}}
